%latex.default(object = result, title = "", file = paste0("tables/",     filename, ".tex"), label = paste0("tb_", type), caption = caption,     insert.bottom = note, first.hline.double = FALSE, rowname = rownames,     cgroup = c("$n = 200$", "", "$n = 1000$", "", "$n = 200$",         "", "$n = 1000$"), n.cgroup = c(2, 1, 2, 2, 2, 1, 2),     cgroupTexCmd = "", colheads = clabels, rgroup = c("Correct PS model",         "Misspecified PS model"), n.rgroup = c(rep(nrow(res1),         2)), longtable = FALSE, center = "centering")%
\begin{table}[!tbp]
\caption{Simulation results: Linear outcome model 2\label{tb_linear2}} 
{\centering
\begin{tabular}{lrrcrcrrcrrcrrcrcrr}
\hline
\multicolumn{1}{l}{\ }&\multicolumn{2}{c}{\ $n = 200$}&\multicolumn{1}{c}{\ }&\multicolumn{1}{c}{\ }&\multicolumn{1}{c}{\ }&\multicolumn{2}{c}{\ $n = 1000$}&\multicolumn{1}{c}{\ }&\multicolumn{2}{c}{\ }&\multicolumn{1}{c}{\ }&\multicolumn{2}{c}{\ $n = 200$}&\multicolumn{1}{c}{\ }&\multicolumn{1}{c}{\ }&\multicolumn{1}{c}{\ }&\multicolumn{2}{c}{\ $n = 1000$}\tabularnewline
\cline{2-3} \cline{7-8} \cline{13-14} \cline{18-19}
\multicolumn{1}{l}{}&\multicolumn{1}{c}{Bias}&\multicolumn{1}{c}{RMSE}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{Bias}&\multicolumn{1}{c}{RMSE}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{Bias}&\multicolumn{1}{c}{RMSE}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{}&\multicolumn{1}{c}{Bias}&\multicolumn{1}{c}{RMSE}\tabularnewline
\hline
{\bfseries Correct PS model}&&&&&&&&&&&&&&&&&&\tabularnewline
~~\textbf{nDBW}&$-0.16$&$  3.77$&&$$&&$-0.05$&$  1.76$&&$$&$$&&$ 0.28$&$ 3.77$&&$$&&$-0.01$&$1.77$\tabularnewline
~~MLE&$-0.12$&$ 10.57$&&$$&&$-0.07$&$  4.51$&&$$&$$&&$-0.10$&$ 9.87$&&$$&&$ 0.00$&$3.71$\tabularnewline
~~CBPS&$ 2.03$&$  5.45$&&$$&&$ 0.35$&$  2.15$&&$$&$$&&$ 2.01$&$ 5.50$&&$$&&$ 0.33$&$2.16$\tabularnewline
~~Calibrated weighting&$ 0.11$&$  3.47$&&$$&&$-0.02$&$  1.58$&&$$&$$&&$-0.02$&$ 3.47$&&$$&&$-0.04$&$1.56$\tabularnewline
~~Entropy balancing&$ 0.11$&$  3.47$&&$$&&$-0.02$&$  1.58$&&$$&$$&&$-0.03$&$ 3.47$&&$$&&$-0.04$&$1.56$\tabularnewline
~~True propensity score&$ 0.12$&$ 22.19$&&$$&&$ 0.35$&$ 10.17$&&$$&$$&&$-0.52$&$19.90$&&$$&&$-0.27$&$8.98$\tabularnewline
~~Unweighted&$-3.59$&$  6.18$&&$$&&$-3.76$&$  4.37$&&$$&$$&&$ 3.76$&$ 6.29$&&$$&&$ 3.73$&$4.34$\tabularnewline
~~\textbf{nDBW DR}&$ 0.07$&$  3.64$&&$$&&$ 0.03$&$  1.65$&&$$&$$&&$ 0.62$&$ 3.66$&&$$&&$ 0.08$&$1.63$\tabularnewline
~~MLE DR&$-0.06$&$  4.89$&&$$&&$-0.13$&$  2.19$&&$$&$$&&$ 0.43$&$ 5.14$&&$$&&$ 0.02$&$2.35$\tabularnewline
~~CBPS DR&$ 0.06$&$  4.40$&&$$&&$-0.08$&$  2.01$&&$$&$$&&$ 0.34$&$ 4.37$&&$$&&$ 0.04$&$2.01$\tabularnewline
~~Calibrated weighting DR&$ 0.10$&$  3.77$&&$$&&$-0.05$&$  1.72$&&$$&$$&&$ 0.37$&$ 3.73$&&$$&&$ 0.06$&$1.67$\tabularnewline
~~Entropy balancing DR&$ 0.02$&$  3.85$&&$$&&$-0.08$&$  1.74$&&$$&$$&&$ 1.18$&$ 3.91$&&$$&&$ 0.95$&$1.91$\tabularnewline
~~True propensity score DR~~&$-0.12$&$  5.19$&&$$&&$-0.09$&$  2.48$&&$$&$$&&$ 0.63$&$ 5.56$&&$$&&$ 0.07$&$2.62$\tabularnewline
~~Imputation&$-3.21$&$  5.78$&&$$&&$-3.36$&$  4.02$&&$$&$$&&$ 5.25$&$ 6.86$&&$$&&$ 5.24$&$5.58$\tabularnewline
\hline
{\bfseries Misspecified PS model}&&&&&&&&&&&&&&&&&&\tabularnewline
~~\textbf{nDBW}&$-4.55$&$  6.45$&&$$&&$-4.62$&$  5.03$&&$$&$$&&$ 4.04$&$ 6.08$&&$$&&$ 1.97$&$2.79$\tabularnewline
~~MLE&$17.20$&$127.21$&&$$&&$36.83$&$234.68$&&$$&$$&&$ 1.47$&$ 9.01$&&$$&&$ 1.39$&$3.63$\tabularnewline
~~CBPS&$-0.42$&$  5.86$&&$$&&$-3.24$&$  4.13$&&$$&$$&&$ 7.43$&$ 9.35$&&$$&&$ 4.56$&$5.16$\tabularnewline
~~Calibrated weighting&$-3.55$&$  5.59$&&$$&&$-3.73$&$  4.18$&&$$&$$&&$ 3.27$&$ 5.33$&&$$&&$ 3.15$&$3.66$\tabularnewline
~~Entropy balancing&$-3.49$&$  5.70$&&$$&&$-3.51$&$  4.03$&&$$&$$&&$ 4.54$&$ 6.33$&&$$&&$ 4.45$&$4.86$\tabularnewline
~~True propensity score&$ 0.19$&$ 22.11$&&$$&&$-0.22$&$ 10.02$&&$$&$$&&$ 0.20$&$20.02$&&$$&&$-0.16$&$9.28$\tabularnewline
~~Unweighted&$-3.88$&$  6.33$&&$$&&$-3.74$&$  4.34$&&$$&$$&&$ 3.69$&$ 6.13$&&$$&&$ 3.73$&$4.36$\tabularnewline
~~\textbf{nDBW DR}&$-3.36$&$  5.48$&&$$&&$-3.56$&$  4.02$&&$$&$$&&$ 3.27$&$ 5.32$&&$$&&$ 2.58$&$3.17$\tabularnewline
~~MLE DR&$-6.05$&$ 17.36$&&$$&&$-9.29$&$ 62.15$&&$$&$$&&$ 4.34$&$ 6.43$&&$$&&$ 4.25$&$4.73$\tabularnewline
~~CBPS DR/BRDR&$-4.42$&$  6.42$&&$$&&$-4.53$&$  4.99$&&$$&$$&&$ 4.44$&$ 6.44$&&$$&&$ 4.49$&$4.95$\tabularnewline
~~Calibrated weighting DR&$-3.55$&$  5.59$&&$$&&$-3.73$&$  4.18$&&$$&$$&&$ 3.27$&$ 5.33$&&$$&&$ 3.15$&$3.66$\tabularnewline
~~Entropy balancing DR&$-3.49$&$  5.70$&&$$&&$-3.51$&$  4.03$&&$$&$$&&$ 4.54$&$ 6.33$&&$$&&$ 4.45$&$4.86$\tabularnewline
~~True propensity score DR~~&$-0.32$&$  5.28$&&$$&&$-0.02$&$  2.42$&&$$&$$&&$ 0.47$&$ 5.75$&&$$&&$ 0.07$&$2.63$\tabularnewline
~~Imputation&$-3.43$&$  5.91$&&$$&&$-3.36$&$  3.95$&&$$&$$&&$ 5.23$&$ 6.83$&&$$&&$ 5.24$&$5.60$\tabularnewline
\hline
\end{tabular}}
\parbox{0.99\textwidth}
		{Notes: This simulation compares the performance of various methods 
		for estimating propensity scores and (inverse probability) weights 
		by investigating combinations of six versions of the true outcome model 
		(linear~1, linear~2, quadratic~1, quadratic~2, exponential~1, and exponential~2)
		and two versions of coefficients for the true propensity score model (type~A and B)
		with the two different numbers of observations ($n = 200$ and $n = 1000$).
		For each estimation method, I use two propensity score model specifications 
		(correct and misspecified) and report the bias and RMSE for each in the table.}\end{table}
